﻿/******************************************************************************
 * 
 * Announce: CSharpKit, Basic algorithms, components and definitions.
 *           Copyright (C) ShenYongchen.
 *           All rights reserved.
 *   Author: 申永辰.郑州 (shenyczz@163.com)
 *  WebSite: http://github.com/shenyczz/CSharpKit
 *
 * THIS CODE IS LICENSED UNDER THE MIT LICENSE (MIT).
 * THIS CODE IS PROVIDED *AS IS* WITHOUT WARRANTY OF 
 * ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING ANY
 * IMPLIED WARRANTIES OF FITNESS FOR A PARTICULAR
 * PURPOSE, MERCHANTABILITY, OR NON-INFRINGEMENT.
 * 
******************************************************************************/

namespace CSharpKit.Numerics.LinearAlgebra.Doubles
{
    /// <summary>
    /// 密集矩阵（Double型） <br/>
    /// 底层存储是列主顺序的一维数组 <br/> 
    /// </summary>
    public class DenseMatrix : Matrix
    {
        public DenseMatrix(int order)
            : this(new MatrixStorageDense<double>(order, order)) { }

        public DenseMatrix(int rows, int columns)
            : this(new MatrixStorageDense<double>(rows, columns)) { }

        public DenseMatrix(int rows, int columns, double[] data)
            : this(new MatrixStorageDense<double>(rows, columns, data)) { }

        public DenseMatrix(MatrixStorageDense<double> storage)
            : base(storage)
        {
            _rowCount = storage.RowCount;
            _columnCount = storage.ColumnCount;
            _values = storage.Data;
        }

        readonly int _rowCount;
        readonly int _columnCount;

        readonly double[] _values;
        public double[] Values => _values;




        // public override Cholesky<double> Cholesky()
        // {
        //     return DenseCholesky.Create(this);
        // }





        //}}@@@
    }


}

